package 设计模式.mediator;

/**
 * @功能
 * @创建时间 2020/5/4
 */
public class Market implements Department {
    private Mediator m;

    public Market(Mediator m) {
        this.m = m;
        m.register("market",this);
    }

    @Override
    public void selfAction() {
        System.out.println("买东西");
    }

    @Override
    public void outAction() {
        System.out.println("找帮主拿钱");
        m.command("finacial");
    }
}
